import "./assets/css/index.less"
import "normalize.css"
import { createApp } from "vue"
import { createPinia } from "pinia"
import registerIcons from "@/global/register-icons"
import  useLoginStrore from "@/stores/login/login"
// 如果您正在使用CDN引入，请删除下面一行。
// import * as ElementPlusIconsVue from '@element-plus/icons-vue'
// import ElementPlus from 'element-plus'


// 针对Message和ElLoadin等组件引入样式
import "element-plus/theme-chalk/el-message.css"
// import 'element-plus/dist/index.css'
import App from "./App.vue"
import router from "./router"

const app = createApp(App)
// 注册所有图标
// for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
//   app.component(key, component)
// }



app.use(createPinia())
// 动态添加路由
const loginStore =useLoginStrore()
loginStore.loadLocalCacheAction()
// app.use(ElementPlus)
app.use(registerIcons)
app.use(router)
app.mount("#app")
